This application describes a video game (hereinafter, simply referred to as a “game”) that progresses while a player object is moved in a virtual space. In the virtual space, objects other than player object, such as enemy objects and construction objects, are set.
In this video game, a virtual camera is set in the virtual space, and a picture of the virtual space, which is obtained by imaging the virtual space by using the virtual camera, is displayed on a game screen. A player plays a game by operating a controller while viewing the game screen. Typically, the virtual camera is set in such a manner that a position, an imaging direction, an angle of view, and the like are variable in accordance with a position and a traveling direction (posture) of the player object.
With regard to a method of controlling the virtual camera, there is a known a video game provided with an attention function capable of paying attention to a specific object (for example, a specific enemy object) in the virtual space, that is, a function of automatically determining a position and a direction of the virtual camera in such a manner that an attention object appears on the game screen while the virtual camera is changing a position and a direction so as to follow a player object.
However, in the video game of the related art, a predetermined restriction is imposed on a direction of the player object, and thus the degree of freedom of operation of the player object is restricted. That is, the position and the direction of the virtual camera are controlled in such a manner that the attention object is shot over the player object from behind the player object, but the direction of the player object is also restricted so as to always face the attention object.
In addition, in the video game of the related art, in a case where when the player object is made to move in a right and left direction, a distance between the player object and the attention object is fixed. Therefore, the movement of the player object is restricted onto the circumference of a circle centering around the attention object, and thus it is difficult for the player object to move in an inclination direction with respect to the attention object. Accordingly, also from this viewpoint, the degree of freedom of the operation of the player object is also restricted.
The technology provides an information processing apparatus which controls a virtual camera so as to shoot an attention object without a restriction on the degree of freedom of operation of a player object, an information processing system, an information processing method, and a non-transitory computer-readable storage medium that stores an information processing program.
According to an example embodiment, there is provided an information processing apparatus that generates an image obtained by imaging a player object and a predetermined object in a virtual space by using a virtual camera, the information processing apparatus comprising: at least one processor, the at least one processor being configured to control at least a position of the player object on the basis of an input by a player, and the at least one processor being further configured to control the virtual camera in such a manner that at least any one of the player object and the predetermined object is included in an imaging range on the basis of the position of the player object and a position of the predetermined object, wherein the at least one processor is configured to control the player object on the basis of the input regardless of the control of the virtual camera.
According to this configuration, the virtual camera is controlled in such a manner that at least any one of the player object and the predetermined object is included in the imaging range on the basis of the position of the player object and the predetermined object in the virtual space, but the player object is controlled on the basis of the input by the player regardless of the control of the virtual camera. According to this, the degree of freedom of operation of the player object is improved. The configuration in which at least any one of the player object and the predetermined object is included in the imaging range also includes a configuration in which a part of at least any one of the player object and the predetermined object is included in the imaging range. That is, at least a part of at least any one of the player object and the predetermined object is included in the imaging range.
The at least one processor may be configured to control at least one of a position, a direction, and an angle of view of the virtual camera. According to this configuration, at least one of the position, the direction, and the angle of view of the virtual camera is controlled in such a manner that at least any one of the player object and the predetermined object is included in the imaging range.
The at least one processor may be configured to select the predetermined object among objects in the virtual space on the basis of an input by the player. According to this configuration, the player can select the predetermined object, which is included in the imaging range of the virtual camera, in the virtual space.
The at least one processor may be configured to carry out the control of the virtual camera on the basis of an input by the player. According to this configuration, a player can initiate the control of the virtual camera in an arbitrary manner.
The at least one processor may be configured to continue the control of the virtual camera during the period in which the input for the control of the virtual camera continues. According to this configuration, during the period in which the input by the player such as pressing of a button continues, the control of the virtual camera, which is carried out by a virtual camera control unit, continues in such a manner that at least any one of the player object and the predetermined object is included in the imaging range.
The at least one processor may be configured to release the control of the virtual camera when the input for the control of the virtual camera is released. According to this configuration, when the input by the player such as the pressing of a button is released, the control of the virtual camera, which is carried out by a virtual camera control unit in such a manner that at least any one of the player object and the predetermined object is included in the imaging range, is released.
The at least one processor may be configured to continue the control of the virtual camera after an input for initiation of the control of the virtual camera is performed until an input for release of the control of the virtual camera is performed. According to this configuration, it is not necessary to continue the input such as the pressing of a button for control of the virtual camera.
The at least one processor may be configured to release the control of the virtual camera when the predetermined object satisfies a predetermined release condition. According to this configuration, in a case where the predetermined object is attacked and disappears, it is possible to release the control of the virtual camera which is carried out in such a manner that at least any one of the player object and the predetermined object is included in the imaging range.
The at least one processor may be configured to control the virtual camera in such a manner that both the player object and the predetermined object are included in the imaging range. According to this configuration, even when the player object moves, the predetermined object can be included in the imaging range. The situation in which both the player object and the predetermined object are included in the imaging range includes a situation in which a part of the player object and a part of the predetermined object are included in the imaging range. That is, both at least a part of the player object and at least a part of the predetermined object are included in the imaging range.
The at least one processor may be configured to control the virtual camera in such a manner that the predetermined object is included in the vicinity of the center of the imaging range. According to this configuration, a captured image, in which the predetermined object exists in the vicinity of the center, is obtained.
The at least one processor may be configured to control the virtual camera in such a manner that the player object is included in the vicinity of the center of the imaging range. According to this configuration, a captured image, in which the player object exists in the vicinity of the center, is obtained.
The at least one processor may be configured to move the virtual camera toward a target position based on a positional relationship between the player object and the predetermined object. According to this configuration, a position of the player object varies on a captured screen, and thus operability of the player object is improved. The virtual camera may linearly move from a current position to a current target position, or may move on a past target position trajectory from the current position to the current target position.
The at least one processor may be configured to control a direction of the virtual camera so as to face a point between the player object and the predetermined object. According to this configuration, a situation, in which both the player object and the predetermined object are included in the imaging range, further increases in comparison to a case where the virtual camera faces either the play object or the predetermined object.
The information processing apparatus may generate an image that is obtained by virtually imaging the virtual space by using a virtual camera that is separate from other virtual camera. According to this configuration, it is possible to display a plurality of images from viewpoints which are different from each other by using a plurality of display devices.
The separate other virtual camera may be controlled in accordance with a direction of the player object. According to this configuration, a subjective viewpoint image is provided.
A captured image of the separate other virtual camera may be displayed on a portable display device that includes an input section for an input by a player. According to this configuration, it is possible to display the subjective viewpoint image on a controller.
According to another example embodiment, there is provided an information processing system that generates an image obtained by imaging a player object and a predetermined object in a virtual space by using a virtual camera, the information processing system including: a controller; and at least one processor, the at least one processor being configured to control at least a position of the player object on the basis of an input to the controller by a player, the at least one processor being further configured to control the virtual camera in such a manner that at least any one of the player object and the predetermined object is included in an imaging range on the basis of the position of the player object and a position of the predetermined object, and the at least one processor being further configured to generate an image captured by the virtual camera, wherein the at least one processor is configured to control the player object on the basis of the input regardless of control of the virtual camera.
According to this configuration, the virtual camera is also controlled in such a manner that at least any one of the player object and the predetermined object is included in the imaging range on the basis of the position of the player object and the predetermined object in the virtual space, but the player object is controlled on the basis of the input by the player regardless of the control of the virtual camera. According to this, the degree of freedom of operation of the player object is improved.
According to still another example embodiment, there is provided an information processing method of generating an image obtained by imaging a player object and a predetermined object in a virtual space by using a virtual camera, including: receiving an input by a player; controlling at least a position of the player object on the basis of the input; and controlling the virtual camera in such a manner that at least any one of the player object and the predetermined object is included in an imaging range on the basis of the position of the player object and a position of the predetermined object, wherein in the controlling of the position of the player object, the player object is controlled on the basis of the input regardless of the control of the virtual camera.
According to this configuration, the virtual camera is also controlled in such a manner that at least any one of the player object and the predetermined object is included in the imaging range on the basis of the position of the player object and the predetermined object in the virtual space, but the player object is controlled on the basis of the input by the player regardless of the control of the virtual camera. According to this, the degree of freedom of operation of the player object is improved.
According to still another example embodiment, there is provided a non-transitory computer-readable recording medium that stores an information processing program of generating an image obtained by imaging a player object and a predetermined object in a virtual space by using a virtual camera, the information processing program allowing a computer to function as at least one processor, the at least one processor being configured to control at least a position of the player object on the basis of an input by a player, and the at least one processor being further configured to control the virtual camera in such a manner that at least any one of the player object and the predetermined object is included in an imaging range on the basis of the position of the player object and a position of the predetermined object, wherein the at least one processor is configured to control the player object on the basis of the input regardless of control of the virtual camera.
According to this configuration, the virtual camera is also controlled in such a manner that at least any one of the player object and the predetermined object is included in the imaging range on the basis of the position of the player object and the predetermined object in the virtual space, but the player object is controlled on the basis of the input by the player regardless of the control of the virtual camera. According to this, the degree of freedom of operation of the player object is improved.